package phapp.dao.data;

import cn.org.rapid_framework.page.Page;
import cn.org.rapid_framework.page.PageRequest;
import org.springframework.stereotype.Component;
import javacommon.base.BaseIbatis3Dao;
import phapp.model.data.*;


/**
  * Title: t_curve_data 数据处理层 
  * Description : 执行./mapper/的CurveMapper.xml的相应SQL语句
  * Copyright: Copyright (c) 2012-10
  * Company: 
  * 
  * @author you name 
  * @version 1.0 
*/

@Component
public class CurveDao extends BaseIbatis3Dao<Curve,java.lang.Integer>{

	public Class getEntityClass() {
		return Curve.class;
	}
	
	public void saveOrUpdate(Curve entity) {
		if(entity.getDataId() == null) 
			save(entity);
		else 
			update(entity);
	}
	
	/**
	* <p>批量删除<br>
	* Description : 
	* @param Curve u
	* @return int
	* @author 
	*/
	public int removeByIdArry(Curve u) {
		int i=-1;
		i =delete("Curve.removeByIdArry", u);
		return i;
	}
	/**
	* <p>分页查询<br>
	* Description : 
	* @param PageRequest pageRequest
	* @return Page
	* @author 
	*/
	public Page findByPageRequest(PageRequest pageRequest) {
		return pageQuery("Curve.pageSelect",pageRequest);
	}
	
	

}
